package com.xiangming.demo.controller;
import com.xiangming.demo.service.imp.LogServiceImpl;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletResponse;


/**
 * @author wxm
 * @data 2021/11/12
 */
@RestController
@Scope
public class LogController {
    Logger logger = LoggerFactory.getLogger(LogController.class);
    @Autowired
    LogServiceImpl logService;
    /**
     * 下载文件接口
     * @param uuid 获取前端id
     * @param response 响应
     */
    @GetMapping("/log")
    public void logDownload(@RequestParam("uuid") String uuid, HttpServletResponse response)  {
        logService.logDownload(uuid, response);
        logger.info("-----debug------请求执行成功");
    }

}
